package a.f.n;

import a.c.bb;
import a.c.e;
import a.c.j;
import a.c.w;
import a.f.o;
import a.f.zc;

import java.util.ArrayList;

public class n
  extends k
{
  public static final byte o = 0;
  public static final byte p = 1;
  private final gb q;
  private final gb r;
  private byte s;
  public static boolean t;
  
  public n(k.b_ paramb_, gb paramgb1, gb paramgb2)
  {
    super(paramb_);
    this.q = paramgb1;
    this.r = paramgb2;
  }
  
  public ib a(d paramd, o paramo, e parame)
  {
    return new a_(paramo, parame);
  }
  
  public void a(e parame, j paramj) {}
  
  public d.a_ a(a.c.k paramk1, a.c.k paramk2, o paramo, e parame, byte paramByte)
  {
    boolean bool2 = k.n;
    boolean bool1 = k.m;
    if (!bool2)
    {
      if (parame.e() == 0) {
        return (d.a_)paramk1.get(parame);
      }
      this.k = paramk1;
      this.j = paramk2;
      this.h = paramo;
      this.l = new ArrayList();
    }
    v localv1 = a(parame);
    double d1 = localv1.h();
    double d2 = localv1.i();
    double d3 = localv1.g();
    double d4 = localv1.d();
    double d5 = localv1.e();
    double d6 = localv1.f();
    bb localbb1 = f(parame);
    bb localbb2 = e(parame);
    int i = 0;
    e locale;
    v localv2;
    v localv3;
    do
    {
      if (i >= localbb1.size()) {
        break;
      }
      locale = (e)localbb1.get(i);
      localv2 = b(locale);
      localv3 = a(locale);
      if (bool1) {
        break label267;
      }
      if (this.s == 0)
      {
        localv2.k(-localv3.h() + d1);
        localv2.h(-localv3.f() + d6);
        if (bool2) {
          continue;
        }
        if (!bool1) {}
      }
      else
      {
        localv2.k(-localv3.e() + d5);
        localv2.h(-localv3.i() + d2);
      }
      localv1.a(localv2);
      i++;
    } while (!bool1);
    if (!bool2) {
      label267:
      i = 0;
    }
    if (i < localbb2.size()) {}
    label395:
    label407:
    while (bool2)
    {
      locale = (e)localbb2.get(i);
      localv2 = b(locale);
      if (bool2) {
        break label422;
      }
      localv3 = a(locale);
      if (bool1) {
        break label420;
      }
      if (!bool2)
      {
        if (this.s == 0)
        {
          localv2.k(-localv3.g() + d3);
          localv2.h(-localv3.f() + d6);
        }
      }
      else
      {
        if (bool2) {
          break label407;
        }
        if (!bool1) {
          break label395;
        }
      }
      localv2.k(-localv3.e() + d5);
      localv2.h(-localv3.d() + d4);
      localv1.a(localv2);
      i++;
      if (!bool1) {
        break;
      }
    }
    localv1.n();
    label420:
    label422:
    return localv1.m();
  }
  
  protected bb e(e parame)
  {
    boolean bool2 = k.n;
    boolean bool1 = k.m;
    bb localbb = new bb();
    int i = parame.e() / 2;
    int j = parame.e() - i;
    int k = 0;
    a.c.d locald = parame.j();
    if (locald != null) {
      if (!bool2) {
        if (k >= j) {
          break label84;
        }
      }
    }
    label84:
    while (bool2)
    {
      localbb.add(locald.f());
      k++;
      locald = locald.k();
      if (!bool1) {
        break;
      }
    }
    return localbb;
  }
  
  protected bb f(e parame)
  {
    boolean bool2 = k.n;
    boolean bool1 = k.m;
    bb localbb = new bb();
    int i = parame.e() / 2;
    int j = 0;
    a.c.d locald = parame.h();
    if (locald != null) {
      if (!bool2) {
        if (j >= i) {
          break label75;
        }
      }
    }
    label75:
    while (bool2)
    {
      localbb.add(locald.f());
      j++;
      locald = locald.i();
      if (!bool1) {
        break;
      }
    }
    return localbb;
  }
  
  protected byte d(e parame)
  {
    throw new IllegalArgumentException("Should not reach");
  }
  
  protected v a(e parame, byte paramByte)
  {
    throw new IllegalArgumentException("Should not reach");
  }
  
  public void c(byte paramByte)
  {
    this.s = paramByte;
  }
  
  public byte e()
  {
    return this.s;
  }
  
  public gb f()
  {
    return this.r;
  }
  
  public gb g()
  {
    return this.q;
  }
  
  private class a_
    implements ib
  {
    private o a;
    private e b;
    private e c;
    private e d;
    
    a_(o paramo, e parame)
    {
      this.a = paramo;
      this.b = parame;
    }
    
    public void a(j paramj1, j paramj2, j paramj3)
    {
      boolean bool2 = k.n;
      boolean bool1 = k.m;
      zc localzc1 = this.a.d(this.b);
      this.c = this.a.i();
      zc localzc2 = this.a.k(this.c);
      localzc2.b(localzc1.c(), localzc1.d());
      localzc2.a(localzc1.a(), localzc1.b());
      paramj1.a(this.c, n.this.q);
      this.d = this.a.i();
      zc localzc3 = this.a.k(this.d);
      localzc3.b(localzc1.c(), localzc1.d());
      localzc3.a(localzc1.a(), localzc1.b());
      paramj1.a(this.d, n.this.r);
      bb localbb1 = n.this.f(this.b);
      bb localbb2 = n.this.e(this.b);
      w localw = localbb1.l();
      e locale;
      a.c.d locald;
      do
      {
        do
        {
          if (!localw.e()) {
            break;
          }
          locale = localw.d();
          locald = this.b.c(locale);
          this.a.a(locald, this.c, locald.f());
          localw.f();
          if (bool2) {
            break label311;
          }
          if (bool1) {
            break label304;
          }
        } while (!bool1);
      } while (bool2);
      localw = localbb2.l();
      label304:
      label311:
      do
      {
        if (!localw.e()) {
          break;
        }
        locale = localw.d();
        locald = this.b.c(locale);
        this.a.a(locald, this.d, locald.f());
        localw.f();
        if ((!bool2) && (bool1)) {
          return;
        }
      } while (!bool1);
      this.a.a(this.b, this.c);
      if (!bool2) {
        this.a.a(this.b, this.d);
      }
    }
    
    public void a()
    {
      boolean bool2 = k.n;
      boolean bool1 = k.m;
      Object localObject = this.c.h();
      a.c.d locald;
      do
      {
        if (localObject == null) {
          break;
        }
        locald = ((a.c.d)localObject).i();
        this.a.a((a.c.d)localObject, this.b, ((a.c.d)localObject).f());
        if (bool2) {
          break label80;
        }
        localObject = locald;
        if (bool1) {
          break label73;
        }
      } while (!bool1);
      if (!bool2)
      {
        this.a.a(this.c);
        label73:
        label80:
        localObject = this.d.h();
        do
        {
          if (localObject == null) {
            break;
          }
          locald = ((a.c.d)localObject).i();
          this.a.a((a.c.d)localObject, this.b, ((a.c.d)localObject).f());
          localObject = locald;
          if ((!bool2) && (bool1)) {
            return;
          }
        } while (!bool1);
        if (bool2) {}
      }
      else
      {
        this.a.a(this.d);
      }
    }
  }
}



/* Location:           E:\idea\

 * Qualified Name:     a.f.n.n

 * JD-Core Version:    0.7.0.1

 */